home *** CD-ROM | disk | FTP | other *** search
- /*
- Miranda Installer - Installs nightlies and Miranda addons.
- Copyright (C) 2002-2003 Goblineye Entertainment
-
- Authors: Saar (Tornado) and Kai (kai_b)
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
- #pragma once
-
- // anything that has to do with the worker thread and its functions, goes here :)
- #include "zlib\unzip.h"
- #include "MirandaInstaller.h"
- #pragma hdrstop
-
- #define DEFAULT_PACKAGENAME "(Unnamed Package)"
-
- // probe script receives it through dwUserData
- // deleted by dialog
- typedef struct XMLPROBE_SCRIPTINFO_TYPE
- {
- unzFile hFile; // zip file
- HWND hwndCtrl; // handle to package selector
- } XMLPROBE_SCRIPTINFO;
-
-
- // returned by parser and package selection dialog
- // list of files to be installed
- // correction - used by a lot of stuff
- typedef struct GENERAL_FILELIST_TYPE
- {
- char *lpFilename; // allocated (be sure to delete). name of file from archive to be installed.
- GENERAL_FILELIST_TYPE *next;
- } GENERAL_FILELIST;
-
-
- // dialog gets it through lParam
- // deleted by dialog when not needed anymore
- typedef struct PACKAGEDLG_EXTRAINFO_TYPE
- {
- unzFile hFile; // zip file
- char *szFilename; // *not* allocated! don't try to delete this one!
- char *lpScript; // script... :) disallocated by caller, not to be touched
- GENERAL_FILELIST *pFileList; // allocated and later deleted by caller dialog. will contain list of files to be installed later.
- } PACKAGEDLG_EXTRAINFO;
-
-
- // extra info when using script to install
- // but w/o dialog
- typedef struct XMLINSTALLER_EXTRAINFO_TYPE
- {
- byte bSolution; // 1 - all, 2 - main
- GENERAL_FILELIST *pFileList; // chain of files to be installed
- } XMLINSTALLER_EXTRAINFO;
-
-
- // autorun info
- typedef struct AUTORUN_INFO_TYPE
- {
- char *lpFilename; // filename mentioned. this means nothing to wether we found an autorun section or not
- byte bState; // LSB - found an autorun section (data is here), 0x2 - type of autorun is document
- } AUTORUN_INFO;
-
-
- DWORD WINAPI InstallerProc(LPVOID lpParameter); // worker thread